package com.liuyucheng.concurrent.waitnotify;

public class WaitNotifyExample {
    public static void main(String[] args) {
        // 创建共享对象
        Message message = new Message();

        // 创建生产者和消费者线程
        Thread producerThread = new Thread(new Producer(message));
        Thread consumerThread = new Thread(new Consumer(message));

        // 启动线程
        producerThread.start();
        consumerThread.start();
    }
}
